home *** CD-ROM | disk | FTP | other *** search
/ NetNews Offline 2 / NetNews Offline Volume 2.iso / news / comp / sys / amiga / programmer / 1158 < prev    next >
Encoding:
Internet Message Format  |  1996-08-05  |  1.1 KB

  1. Path: newshub.csu.net!clstac!cdubose
  2. From: cdubose@csupomona.edu
  3. Newsgroups: comp.sys.amiga.programmer
  4. Subject: Re: Is this a SAS/C bug or have I coded it wrong?
  5. Date: 15 Jan 96 21:46:11 PST
  6. Organization: California State Polytechnic University, Pomona
  7. Message-ID: <1996Jan15.214611@clstac>
  8. References: <4cfrc5$gsc@misery.millcomm.com>
  9. NNTP-Posting-Host: bronco.is.csupomona.edu
  10.  
  11. In article <4cfrc5$gsc@misery.millcomm.com>, llucius@millcomm.com (Yambo) writes:
  12. >       if ( tmpbuf[0] & 0x1f == 1 )
  13. >          return 1;
  14. >       return 0;
  15.  
  16. Like everybody else said, it should be:
  17.   if ( (tmpbuf[0] & 0x1f) == 1 )
  18.  
  19. But is this really what you want?
  20.  
  21. That expression is equivalent to (tmpbuf[0] % 32 == 1).
  22.  
  23. I suppose it is.
  24.  
  25. > -- 
  26. > __ Y_ a_ m_ b_ o_ | The leanest, meanest, fightinest sweet tater on Earth!
  27. >    oo o  oo o  o  | 
  28. >     o       o   o | llucius@millcomm.com
  29. >  o oo    o     o  | 
  30. > -- -- -- -- -- -- | http://www.millcomm.com/~llucius/index.html (coming soon)
  31.  
  32. -- Chris DuBose, Cal Poly Pomona computer scientist, cdubose@csupomona.edu
  33. Fan of Queen, Moria, Star Trek, Seattle, Torey Hayden, and the Amiga
  34.